package br.com.infoanalise.pety.domain;

import javax.persistence.EntityManager;
import javax.persistence.EntityManagerFactory;
import javax.persistence.Persistence;

public class CriarBanco {

	public static void main(String[] args) {
		EntityManagerFactory factory = Persistence
				.createEntityManagerFactory("copadomundo");

		EntityManager em = factory.createEntityManager();

		Selecao selecao = new Selecao();
		selecao.setPais("Brasil");
		selecao.setTecnico("Zagalo");

		em.getTransaction().begin();
		em.persist(selecao);
		em.getTransaction().commit();

		
		factory.close();
		
	}

}
